<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org"
      xmlns:sec="http://wwww.thymeleaf.org/thymeleaf-extras-springsecurity5">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
    main1.html
    <br/>
    基于权限控制
    <button sec:authorize="hasAuthority('insert')">新增</button>
    <button sec:authorize="hasAuthority('delete')">删除</button>
    <button sec:authorize="hasAuthority('update')">修改</button>
    <button sec:authorize="hasAuthority('select')">查看</button>
    <br/>
    基于角色控制
    <button sec:authorize="hasRole('admin')">新增</button>
    <button sec:authorize="hasRole('admin')">删除</button>
    <button sec:authorize="hasRole('admin')">修改</button>
    <button sec:authorize="hasAnyRole('normal','admin')">查看</button>
</body>
</html>